package base;

public class ChatString {
	private String chatText;

	public ChatString(String chatText) {
		super();
		this.chatText = chatText;
	}

	public boolean isGameChat() {
		return !chatText.contains(":");
	}

	public boolean isPlayerChat() {
		return chatText.contains(":");
	}

	public boolean isPlayerChat(String playerName) {
		return chatText.split(":")[0].equalsIgnoreCase(playerName);

	}

	public String getMessage() {
		return chatText;
	}
}
